package com.extra_archive.project.iisu.view.detail 
{
	import com.extra_archive.framework.core.mvc.controller.IController;
	import com.extra_archive.framework.core.mvc.model.IModel;
	import com.extra_archive.framework.core.mvc.view.CompositeView;
	import com.extra_archive.project.iisu.model.ARModel;
	import com.extra_archive.project.iisu.model.ARModelEvent;
	import com.extra_archive.project.iisu.view.IARState;

	/**
	 * @class name : ARDetailView
	 * @author : implict (http://extra-archive.com)
	 * @date : 2010. 4. 29.
	 * @description :
	 */
	public class ARDetailView extends CompositeView implements IARState
	{
		private var _content : BasicDetailComponentView;
		
		public function ARDetailView(model : IModel = null, controller : IController = null)
		{
			super(model, controller);
		}
		
		//--------------------------------------------------------------------------
		//
		//    Public Methods
		//
		//--------------------------------------------------------------------------

		override public function initialize() : void
		{
			
		}
		
		public function live() : void
		{
			//TODO : section index로 변경
			setContent(ARModel(_model).assetManager.detailSwfs[0]);
			_content.live();
		}

		public function kill() : void
		{
			_content.kill();
			if (_content) removeChild(_content);
		}
		
		public function setContent(content : BasicDetailComponentView) : void
		{
			_content = content;
			addChild(_content);
		}
		
		//--------------------------------------------------------------------------
		//
		//    Event Listeners
		//
		//--------------------------------------------------------------------------
		
		//--------------------------------------------------------------------------
		//
		//    Private Methods
		//
		//--------------------------------------------------------------------------
	}
}
